package kr.example.kaist_yasik;

import java.util.ArrayList;
import java.util.List;

class Cate{
	String catename;
	String subname;
	List<Contact> datalist;
	
	public String getName(){return catename;}
	public String getSubName(){return subname;}
	public List<Contact> getData(){return datalist;}
	public void add(Contact t){
		datalist.add(t);
	}
	Cate(String c, String sb){
		catename = c;
		subname = sb;
		datalist = new ArrayList<Contact>();
	}
	public String[] getList(){
		String[] rtn = new String[datalist.size()];
		for(int i = 0; i < datalist.size(); i++){
			rtn[i] = datalist.get(i).getName();
		}
		
		return rtn;
	}
}